package com.ada.jodd;

import jodd.http.HttpRequest;

public class HttpApp {

    public static void main(String[] args) {

//        HttpBrowser browser = new HttpBrowser();
//        browser.setKeepAlive(true);
//        browser.setDefaultHeader("User-Agent","Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:90.0) Gecko/20100101 Firefox/90.0");
//        browser.setDefaultHeader("Accept","text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,*/*;q=0.8");
//        HttpRequest request = HttpRequest.get("https://bytedance.com/zh/");
//        browser.sendRequest(request);
//// request is sent and response is received
//// process the HTML page
//
//        browser.sendRequest(HttpRequest.get("https://jobs.bytedance.com"));


        HttpRequest request1=HttpRequest.post("https://jobs.bytedance.com/api/v1/search/job/posts");
        request1.form("offset", "10")
                .form("limit", "10");
        System.out.println(request1);
// create new request
    }
}
